Battery energy storage system and microgrid controller

ABSTRACT

This invention is directed to systems and methods that track a specified stored energy level profile for a BESS in a microgrid. The systems and methods including using a control algorithm that tracks the stored energy level profile for the BESS. The controller algorithm includes a Kalman Filter design for a model-based state reconstruction to overcome sensor/communication errors during real-time operation. The latter is important to guarantee the ability of the microgrid to continue its seamless operation during periods of erroneous sensor measurements or flawed communication.

CROSS-REFERENCE PARAGRAPH

This application claims the benefit of U.S. Non-Provisional patentapplication Ser. No. 16/720,558, filed on Dec. 19, 2019, entitled“BATTERY ENERGY STORAGE SYSTEM AND MICROGRID CONTROLLER” now U.S. Pat.No. 11,128,137 which claims priority to U.S. Provisional Application No.62/781,522 filed on Dec. 18, 2018, entitled “BATTERY ENERGY STORAGESYSTEM AND MICROGRID CONTROLLER”, the contents of both of which areincorporated herein by reference as though set forth in their entirety.

FIELD OF INVENTION

The present disclosure generally relates to the field of Battery EnergyStorage Systems (“BESS”). More particularly, the present disclosuregenerally relates to controlling a stored energy level of a BESS in amicrogrid.

BACKGROUND OF THE INVENTION

A microgrid is a localized grouping of electricity generation, energystorage, and loads that normally operates connected to a traditionalcentralized grid (power distribution grid or macrogrid) via a point ofcommon coupling (PCC). This single point of common coupling with themacrogrid can be disconnected, islanding the microgrid. Microgrids arepart of a structure aiming at producing electrical power locally frommany distributed energy resources (DERs). In a microgrid, a DER isconnected via a converter which controls the output of the DER, i.e. thecurrent injected into the microgrid. DERs may include renewable and/ornon-renewable energy resources.

A microgrid (in grid connected mode, i.e. connected to the distributiongrid) supplies the optimized or maximum power outputs from the connectedDER sites and the rest of the power is supplied by the distributiongrid. The microgrid is connected to the distribution grid at a PCCthrough a controllable switch/breaker. This grid connection is lost whenthe breaker is open during grid fault and the microgrid is islanded.

A microgrid is controlled by a controller, which may be centralized ordistributed, which e.g. controls DERs in accordance with voltage orcurrent control schemes. One of the aspects of microgrid control isefficient control of the grid interface at the PCC. Various conditionse.g. power flow, voltage, disconnection or power factor at the PCCimpose different control requirements within the microgrid.

In some environments, power generation systems using renewable resourcesmay be used as DERS and be integrated into a microgrid. Power productionfrom the conversion of energy produced by renewable resource, such asPhotovoltaic (PV) and Wind energy systems, may be highly variable andunpredictable. Variability of power production can be mitigated by theuse of a battery energy storage system (BESS) to allow temporary storageand dispatch of power in a microgrid. However, a BESS has a limitedenergy storage capability characterized by the size or capacity of thebattery. It is important to keep the stored energy level of the BESSwithin operation limits to avoid over-charging or under-charging of theBESS. Keeping the stored energy level of the BESS within operatinglimits can be done by real-time monitoring and control.

Thus, what is needed are systems and methods that track a specifiedstored energy level profile for a BESS in a microgrid.

SUMMARY

The following presents a simplified overview of the example embodimentsin order to provide a basic understanding of some embodiments of theexample embodiments. This overview is not an extensive overview of theexample embodiments. It is intended to neither identify key or criticalelements of the example embodiments nor delineate the scope of theappended claims. Its sole purpose is to present some concepts of theexample embodiments in a simplified form as a prelude to the moredetailed description that is presented hereinbelow. It is to beunderstood that both the following general description and the followingdetailed description are exemplary and explanatory only and are notrestrictive.

This invention is directed to systems and methods that track a specifiedstored energy level profile for a BESS in a microgrid. The systems andmethods including using a control algorithm that tracks the storedenergy level profile for the BESS. The controller algorithm includes aKalman Filter design for a model-based state reconstruction to overcomesensor/communication errors during real-time operation. The latter isimportant to guarantee the ability of the microgrid to continue itsseamless operation during periods of erroneous sensor measurements orflawed communication.

In the present disclosure, attributes of a battery energy storage system(BESS) and the stored energy level of a BESS are characterized. In oneembodiment, attributes of a battery energy storage system (BESS) mayrefer to the capacity of the BESS indicating the total energy that maybe stored in the BESS. In another embodiment, an absolute measure forthe stored energy level of the BESS is continuously received. In otherembodiments, a relative measure of stored energy level of the BESS iscontinuously received.

In one embodiment, data representing absolute measure for the storedenergy level of the BESS may refer to energy in Joules (J), Watt-hour(Wh), Kilowatt-hour (KWh) or Megawatt-hour (MWh) of energy. In anotherembodiment, data representing relative measure for the stored energylevel of the BESS may refer to the State of Charge (SoC) in percentageof the ratio of the absolute measure for the stored energy divided bythe total energy that can be stored in the BESS.

A control data stream for the BESS is continuously generated. In oneembodiment, the control data stream may refer to the current dispatchcommands sent to the BESS. In another embodiment, the control datastream for the BESS may refer to AC real power dispatch commands sent toan inverter integrated with the BESS.

The control data stream for the BESS is continuously generated by afeedback control algorithm that is continuously processing a referencedata stream and a feedback data stream. In an embodiment, the referencedata stream may be data representing the desired absolute measure forthe stored energy level of the BESS. In other variations, the referencedata stream may be data representing the desired relative measure forthe stored energy level of the BESS.

In one embodiment, the feedback data stream may be measurementsrepresenting the absolute measure for the stored energy level of theBESS. In another embodiment, the feedback data stream may bemeasurements representing relative measure for the stored energy levelof the BESS. In yet another embodiment, the feedback data stream mayhave intermittently incorrect or erroneous measurements representing theabsolute or relative measure for the stored energy level of the BESS.

In one embodiment, the feedback control algorithm is the combination ofswitching logic and dynamic filters that ensures that the absolute orrelative measure for the stored energy level of the BESS is stabilizedand kept constant. In another embodiment, the feedback control algorithmis the combination of switching logic and dynamic filters that ensuresthat the absolute or relative measure of the stored energy level of theBESS is tracking or following the reference data stream representing thedesired absolute or relative measure of the stored energy level of theBESS.

The present disclosure provides an innovative solution to control theabsolute or relative measure of the stored energy level of the BESS bycontrolling the power flow of a BESS. The subject matter describedherein provides many technical advantages by combining three keyinventions: (a) the use of real-time feedback measurement of theabsolute or relative measure of the stored energy level of the BESS, (b)the continuous generation of power demand or current demand signals forthe BESS, and (c) the ability to handle intermittently incorrect orerroneous measurements representing the absolute or relative measure forthe stored energy level of the BESS.

Still other advantages, embodiments, and features of the subjectdisclosure will become readily apparent to those of ordinary skill inthe art from the following description wherein there is shown anddescribed a preferred embodiment of the present disclosure, simply byway of illustration of one of the best modes best suited to carry outthe subject disclosure As it will be realized, the present disclosure iscapable of other different embodiments and its several details arecapable of modifications in various obvious embodiments, all withoutdeparting from, or limiting, the scope herein. Accordingly, the drawingsand descriptions will be regarded as illustrative in nature and not asrestrictive.

BRIEF DESCRIPTION OF THE DRAWINGS

The drawings are of illustrative embodiments. They do not illustrate allembodiments. Other embodiments may be used in addition or instead.Details which may be apparent or unnecessary may be omitted to savespace or for more effective illustration. Some embodiments may bepracticed with additional components or steps and/or without all of thecomponents or steps which are illustrated. When the same numeral appearsin different drawings, it refers to the same or like components orsteps.

FIG. 1 is a schematic illustration of an embodiment of a microgrid inaccordance with the present disclosure.

FIG. 2 is a schematic illustration of an embodiment of a microgridcontroller used in connection with a microgrid in accordance with thepresent disclosure.

FIG. 3 is a flowchart illustrating one method for monitoring andcontrolling power within a microgrid in accordance with the presentdisclosure.

FIG. 4 are graphs depicting an example of monitoring and controllingpower within a microgrid in accordance with the present disclosure.

FIG. 5 is a functional block diagram of a microgrid controller appliedto a Simplified Dynamic Power Model (SDPM).

FIG. 6 is a functional block diagram of an SDPM modeling the dynamics ofthe microgrid.

FIG. 7 is a functional block diagram of a microgrid which includes adistribution energy resource (DER).

FIG. 8 is a block diagram of a Rate Limiter Operation (RLO) module of amicrogrid controller.

FIG. 9 is an illustration of a microgrid controller for controlling aninverter at the Kaiser Permanente Richmond Medial Center (KPRMC).

FIG. 10 is a diagram of the modelled microgrid at KPRMC.

FIG. 11 is a diagram of a communication setup for CHIL testbed incommunication with a microgrid controller and a microgrid simulator.

FIG. 12 is a chart illustrating real and reactive power flow outputsignals due to real and reactive flow input demand signals at a POI.

FIG. 13 are charts illustrating real power demand levels within themodelled microgrid.

FIG. 14 are charts illustrating decoupled real and reactive power levelswithin the modelled microgrid.

FIG. 15 are charts illustrating (decoupled) real power levels within themodelled microgrid.

FIG. 16 are charts illustrating (decoupled) real power disturbancerejection within the modelled microgrid.

FIG. 17 is a one-line diagram illustrating the KPRMC microgrid.

FIG. 18 is a diagram illustrating hardware setup for the cyber-securesynchrophasor platform at the KPRMC microgrid.

FIG. 19 are diagrams illustrating hardware equipment chassisconfigurations for the KPRMC microgrid.

FIG. 20 are charts illustrating real time measurements from selectedPMU's within the KPRMC microgrid.

FIG. 21 are charts illustrating the dynamic characterization of realpower flow within the KPRMC microgrid.

FIG. 22 are charts illustrating the power tracking capabilities of themicrogrid controller applied to the KPRMC microgrid.

FIG. 23 are charts illustrating results from closed-loop testing of theSoC-gated microgrid control by the microgrid controller within the KPRMCmicrogrid.

FIG. 24 are charts illustrating results from closed-loop testing of theSoC-gated microgrid control by the microgrid controller within the KPRMCmicrogrid.

FIG. 25 are charts illustrating the daily real power PV production andinverter output, PCC power demand, and SoC within the KPRMC microgrid.

FIG. 26 are charts illustrating the multi-daily real power PV productionand inverter output, PCC power demand, and SoC within the KPRMCmicrogrid.

DETAILED DESCRIPTION OF THE ILLUSTRATIVE EMBODIMENTS

Before the present methods and systems are disclosed and described, itis to be understood that the methods and systems are not limited tospecific methods, specific components, or to particular implementations.It is also to be understood that the terminology used herein is for thepurpose of describing particular embodiments only and is not intended tobe limiting.

As used in the specification and the appended claims, the singular forms“a,” “an,” and “the” include plural referents unless the context clearlydictates otherwise. Ranges may be expressed herein as from “about” oneparticular value, and/or to “about” another particular value. When sucha range is expressed, another embodiment includes from the oneparticular value and/or to the other particular value. Similarly, whenvalues are expressed as approximations, by use of the antecedent“about,” it will be understood that the particular value forms anotherembodiment. It will be further understood that the endpoints of each ofthe ranges are significant both in relation to the other endpoint, andindependently of the other endpoint.

“Optional” or “optionally” means that the subsequently described eventor circumstance may or may not occur, and that the description includesinstances where said event or circumstance occurs and instances where itdoes not.

Throughout the description and claims of this specification, the word“comprise” and variations of the word, such as “comprising” and“comprises,” means “including but not limited to,” and is not intendedto exclude, for example, other components, integers or steps.“Exemplary” means “an example of” and is not intended to convey anindication of a preferred or ideal embodiment. “Such as” is not used ina restrictive sense, but for explanatory purposes.

Disclosed are components that may be used to perform the disclosedmethods and systems. These and other components are disclosed herein,and it is understood that when combinations, subsets, interactions,groups, etc. of these components are disclosed that while specificreference of each various individual and collective combinations andpermutation of these may not be explicitly disclosed, each isspecifically contemplated and described herein, for all methods andsystems. This applies to all embodiments of this application including,but not limited to, steps in disclosed methods. Thus, if there are avariety of additional steps that may be performed it is understood thateach of these additional steps may be performed with any specificembodiment or combination of embodiments of the disclosed methods.

The present methods and systems may be understood more readily byreference to the following detailed description of preferred embodimentsand the examples included therein and to the Figures and their previousand following description.

In the following description, certain terminology is used to describecertain features of one or more embodiments. For purposes of thespecification, unless otherwise specified, the term “substantially”refers to the complete or nearly complete extent or degree of an action,characteristic, property, state, structure, item, or result. Forexample, in one embodiment, an object that is “substantially” locatedwithin a housing would mean that the object is either completely withina housing or nearly completely within a housing. The exact allowabledegree of deviation from absolute completeness may in some cases dependon the specific context. However, generally speaking, the nearness ofcompletion will be so as to have the same overall result as if absoluteand total completion were obtained. The use of “substantially” is alsoequally applicable when used in a negative connotation to refer to thecomplete or near complete lack of an action, characteristic, property,state, structure, item, or result.

As used herein, the terms “approximately” and “about” generally refer toa deviance of within 5% of the indicated number or range of numbers. Inone embodiment, the term “approximately” and “about”, may refer to adeviance of between 0.00110% from the indicated number or range ofnumbers.

Various embodiments are now described with reference to the drawings. Inthe following description, for purposes of explanation, numerousspecific details are set forth in order to provide a thoroughunderstanding of one or more embodiments. It may be evident, however,that the various embodiments may be practiced without these specificdetails. In other instances, well-known structures and devices are shownin block diagram form to facilitate describing these embodiments.

In accordance with the embodiments disclosed herein, the presentdisclosure is directed systems and methods that track a specified storedenergy level profile for a BESS in a microgrid. The systems and methodsincluding using a control algorithm that tracks the stored energy levelprofile for the BESS. The controller algorithm includes a Kalman Filterdesign for a model-based state reconstruction to overcomesensor/communication errors during real-time operation. The latter isimportant to guarantee the ability of the microgrid to continue itsseamless operation during periods of erroneous sensor measurements orflawed communication.

I. Systems and Methods for Controlling Stored Energy Level of BESS

FIG. 1 illustrates one embodiment of a microgrid arrangement 100 of thepresent disclosure. The microgrid 100 includes a Photovoltaic (PV) DER102 and a BESS 104 connected to inverter 106. The inverter 106 isconnected to at least one the plurality of loads 108 and providescurrent or power thereto. As shown in this embodiment, PV 102 and BESS104 produce direct current (DC), whereas the microgrid 100 carriesalternating current (AC), and therefore must convert the receivedcurrent from DC to AC for transmission to the loads 108. The inverter106 includes one or more DC port connections 106 a for connection withDC-producing DERs and one or more AC port connections 106 b forconnection to one or more loads 108. Microgrid 100 is connected to amain power grid 110 via a point of common coupling (PCC) 112. While FIG.1 depicts two DERs, it is understood that the microgrid 100 may includeany number of DERs as required for efficient operation thereof. In theembodiment illustrated in FIG. 1. PV 102 generates solar power which isprovided to inverter 106 as shown at 114. The BESS 104 provides andreceives power to the inverter 106 as shown at 116.

In one embodiment, the inverter 106 is configured to provide ameasurement of photovoltaic power as indicated by PV at 118 and theState of Charge of the BESS 104 as indicated by SoC at 120. Actualmeasurement of the real or active power produced by the inverter 106 isindicated by P at 122.

As shown in FIG. 1, inverter 106 operates as current source for one ormore loads 108. In addition, the inverter 106 may include a power demandor dispatch signal P_(ref) 124 used to modulate the active power demandat the AC port of the inverter 106. Without such P_(ref), the inverter106 may store photovoltaic power generated by the PV 102 in the BESS 104causing the SoC 120 of the BESS.

Using the notation c(t_(k)) to denote the stored energy or charge of theBESS 104 at time t_(k), PV(t_(k)) to denote the solar power produced byPV 102 at time t_(k) and P(t_(k)) to denote the actual active powerproduced by the inverter 106 at time t_(k), we may writec(t _(k))=c(t _(k-1))+η₁ ·T _(s) ·PV(t _(k-1))+η₂ ·T _(s) ·P(t_(−1k))  (1)where T_(s) denotes the sampling time or time difference betweenc(t_(k)) and c(t_(k-1)). Furthermore, the coefficients 0<η₁≤1 and 0<η₂≤1may be used to model for the efficiency respectively of the solar powerPV(t_(k)) to charge the BESS 104 and for the active power demandP(t_(k)) to discharge the BESS 104. The result in Eq. (1) indicates arecursive formula for the computation of the charge c(t_(k)) at the timesample t_(k) as function of the charge c(t_(k-1)) at the previous timesample t_(k-1) based on a measurement of the solar power PV(t_(k-1)) andthe measurement of active power P(t_(k-1)) at time sample t_(−1k). Theunit c(t_(k)) in Eq. (1) is determined by the product of equivalentunits of power used for the solar power S(t_(k)) and the active powerP(t_(k)) and the unit of time in seconds. Multiplication of c(t_(k))with 3600 leads to the units determined by the product of equivalentunits of power used for the solar power PV(t_(k)) and the active powerP(t_(k)) and the unit of time in hour. For example, with PV(t_(k)) andP(t_(k)) in the units of kW, 3600·c(t_(k)) will have the units of kWh.

The BESS 104 may have a limited energy storage capacity capabilitycharacterized by the size or capacity of the battery. Denoting the sizeor capacity of the battery by the parameters C and expressed in the sameunits as the charge c(t_(k)), we may define the notion of State ofCharge by

${{SoC}\left( t_{k} \right)} = {\frac{c\left( t_{k} \right)}{C} \cdot 100}$where SoC(t_(k)) is given in units of %.

It may be important to keep the stored energy c(t_(k)) or the equivalentstate of charge SoC(t_(k)) of the BESS 104 within operation limits toavoid over-charging or under-charging of the BESS 104. Keeping thestored energy level of the BESS 104 within operating limits may be doneby real-time monitoring and control.

FIG. 2 is a schematic illustration of a microgrid controller 202configured to operate in connection with the inverter 106. In oneembodiment, the microgrid controller 202 computes the inverter active orreal power dispatch signal P_(ref) 124 by tracking or following an SoCreference signal SoC_(ref) illustrated as 204. As shown in FIG. 2, apreferred embodiment may comprise real-time monitoring and control tokeep the stored energy c(t_(k)) or the equivalent state of chargeSoC(t_(k)) of the BESS 104 within operation limits. In the preferredembodiment, measurements of the state of charge SoC(t_(k)), solar powerPV(t_(k)) and active power produced by the inverter P(t_(k)) may form afeedback data stream 206 and a desired or reference state of chargeSoC(t_(k)) may be the reference data stream 204. In another embodiment,measurements of the charge c(t_(k)), solar power PV(t_(k)) and activepower produced by the inverter P(t_(k)) may form a feedback data stream206 and a desired or reference charge c(t_(k)) may be the reference datastream 204.

Measurements of the stored energy c(t_(k)) or the equivalent state ofcharge SoC(t_(k)) of the BESS 104 available in the feedback stream ofFIG. 1 may be characterized byx(t _(k))=x(t _(k-1))+η₁ ·T _(s) ·PV(t _(k-1))+η₂ ·T _(s) ·P(t_(k-1))+w(t _(k))  (2)andc(t _(k))=H(t _(k))·x(t _(k))+v(t _(k))  (3)where the two noise contributions v(t_(k)) in Eq. (2) and w(t_(k)) inEq. (3) may be used to denote, respectively, process noise andmeasurement errors present on the measurement of c(t_(k)).

The process noise w(t_(k)) in Eq. (2) may have a mean value of 0 and avariance Q. The process noise w(t_(k)) is used to model the effect ofrandom fluctuations in the dynamic progression of the stored energyx(t_(k)) of the BESS 104. It may be observed from Eq. (1) thatx(t_(k))=c(t_(k)) in case w(t_(k))=0.

The measurement noise v(t_(k)) in Eq. (3) may have a mean value of 0 anda variance R. The measurement noise v(t_(k)) is used to model the effectof random fluctuations in the measurement of the stored energy c(t_(k))of the BESS 104. Finally, the amplification H(t_(k)) in Eq. (3) is usedto indicate missing or erroneous data points of the stored energyc(t_(k)) or the equivalent state of charge SoC(t_(k)). In caseH(t_(k))=1, the mean value of c(t_(k)) will be equal to the mean valueof x(t_(k)). However, H(t_(k)) #1, the BESS 104 may report an erroneousmeasurement or a missing measurement. In case of a missing measurement,one may assuming c(t_(k))=c(t_(k-1)) making H(t_(k))=0 andv(t_(k))=−η₁·T_(s)·PV(t_(k-1))−η₂·T_(s)·P(t_(k-1))−w(t_(k)).

As shown in FIG. 2, the microgrid controller 202, using a feedbackcontrol algorithm, may continuously process a reference data stream 204and a feedback data stream 206 to compute a desired active powerdispatch signal P_(ref)(t_(k)) at time t_(k) for the inverter 106 toeither charge, discharge, or level the energy or charge level of theBESS 104. In a preferred embodiment, the feedback control algorithm maybe the combination of switching logic and dynamic filters so that thatthe absolute or relative measure of the stored energy level of the BESS104 is tracking or following the reference data stream 204 representingthe desired absolute or relative measure of the stored energy level ofthe BESS 104.

FIG. 3 provides an overview of a discrete-time feedback control method300 used by the microgrid controller 202 to compute the inverter activeor real power dispatch signal P_(ref) 124 from the SoC measurementsignal 120 and the desired SoC reference signal SoC_(ref) 204. Toaccommodate the process noise w(t_(k)) as indicated in Eq. (2),measurement noise v(t_(k)) and erroneous measurements H(t_(k)) #1 of thestored energy c(t_(k)) in Eq. (3), the feedback control algorithm mayfirst process the measurement c(t_(k)) via a Kalman filter 302. TheKalman filter 302 may provide an estimate y(t_(k)) of the stored energyc(t_(k)) or the equivalent state of charge SoC(t_(k)) of the BESS 104via the measurement update:y(t _(k))=(1−L(t _(k))H(t _(k)))y(t _(k-1))+η₁ ·T _(s) ·PV(t _(k-1))+η₂·T _(s) ·P(t _(k-1))+L(t _(k))c(t _(k))  (4)where H(t_(k)) was given in Eq. (3) and the Kalman gain L(t_(k)) iscomputed by:

$\begin{matrix}{{L\left( t_{k} \right)} = {{P\left( t_{k} \right)} \cdot \frac{H\left( t_{k} \right)}{{{H\left( t_{k} \right)}^{2} \cdot {P\left( t_{k} \right)}} + R}}} & (5)\end{matrix}$where R is the variance measurement noise v(t_(k)) in Eq. (3) andP(t_(k)) is the progression of the covariance given by the recursiveformulation:

$\begin{matrix}{{P\left( t_{k} \right)} = {{P\left( t_{k - 1} \right)} + \frac{{P\left( t_{k - 1} \right)}^{2} \cdot {H\left( t_{k} \right)}}{{{H\left( t_{k} \right)}^{2} \cdot {P\left( t_{k - 1} \right)}} + R} + Q}} & (5)\end{matrix}$where Q is the variance measurement noise w(t_(k)) in Eq. (2). Thecombination of Eq. (2) and Eq. (4) leads to an errore(t_(k))−x(t_(k))−y(t_(k)) that can be described by the recursive errorequation:e(t _(k))=(1−L(t _(k))H(t _(k)))e(t _(k-1))+w(t _(k-1))−L(t _(k))V(t_(k-1))  (6)

For measurements of the stored energy c(t_(k)) in Eq. (3) without errorsit is known that H(t_(k))=1 and the filter gain L(t_(k)) may be chosenas a fixed and time independent gain L(t_(k))=L with the condition 0<L<2to ensure the mean value of e(t_(k)) x(t_(k))−y(t_(k)) converges to 0according to the recursive error equation (6).

Because there is no explicit knowledge on when errors occur in themeasurement of the stored energy c(t_(k)) in Eq. (3) or equivalently,when H(t_(k))≠1, significant errors e(t_(k)) may indicate deviation fromH(t_(k))=1. In a preferred embodiment, Kalman filter 302 may include anerror detection algorithm 304 based on a threshold:|e(t _(k))|=|y(t _(k))−c(t _(k))|>ϵ  (7)for detecting erroneous errors in the measurement of the stored energyc(t_(k)). Once an erroneous measurement is flagged according to Eq. (7),the Kalman filter 302 may switch to a Kalman gain L(t_(k))=0. WhereL(t_(k))=0, the estimate y(t_(k)) in Eq. (4) may reduce back to theformat of Eq. (1) where the Kalman filter reconstruct the of the storedenergy y(t_(k)) of the BESS 104 with no dependence on the measured storeenergy c(t_(k)) of the BESS 104.

Following the flow diagram of the control algorithm in FIG. 3, thefiltered value y(t_(k)) of the measurement of the stored energy c(t_(k))of the BESS 104 may be to send a Proportional and Integral (PI) filter306 described byP _(ref)(t _(k))−P _(ref)(t _(k))+K _(p) ·d(t _(k))+K _(i) ·T _(s) ·d(t_(k-1))+η₁ ·PV(t _(k))  (7)to compute the power demand or dispatch signal P_(ref)(t_(k)) at thetime sample t_(k), where d(t_(k))=SoC_(ref)(t_(k))−SoC(t_(k)) is theerror between the desired SoC reference SoC_(ref)(t_(k)) and themeasured SoC value SoC(t_(k)). The parameter η₁ with 0<η₁≤1 is again theefficiency respectively of the solar power PV(t_(k)) to charge thebattery similar as in Eq. (1). Additional filtering, slew rate, andamplitude limits can be imposed onto the dispatch signal P_(ref)(t_(k))to stay within the operating range of the inverter 106.

FIG. 4 illustrates the results of the implementation of the real-timeenergy control to dispatch power demand signal P_(ref) (t_(k)) to theinverter 106 of a BESS 104, and track a desired SoC profileSoC_(ref)(t_(k)) with the measurements of the state of charge SoC(t_(k))of a BESS. The experimental results of FIG. 4 have been obtained by theimplementation of a microgrid with a BESS 104 and a PV DER 102 at amedical facility microgrid in Northern California. Measurements of thesolar power PV(t_(k)), state of charge SoC(t_(k)) of a BESS 104 andresulting power demand signals P(t_(k)) of the inverter 106 areimplemented via Modbus communication over TCP/IP with an update rate of1 Hz. The feedback control process described in FIG. 3 along with theKalman filter 302, error detection logic 304, and Proportional andIntegral filter 306 is coded in C++ and implemented in SchweitzerEngineering Laboratories (SEL) 3355 computer. The inverter powerdispatch and PV power are shown in the top of FIG. 4. The performance onSoC tracking is shown in the bottom of FIG. 4. The SoC may be trackedwith the subject matter, despite sporadic erroneous measurements in theSoC. The microgrid controller 202 may also track the desired SoC profilewith a single charge/discharge cycle through the day, maintaining theSoC of the BESS between 30% and 80%, despite the highly variable PVpower generation present while running the experiment.

II. Experimental

The following examples are provided in order to demonstrate and furtherillustrate certain preferred embodiments and aspects of the presentdisclosure and are not to be construed as limiting the scope thereof.

A. Features and Capabilities of the Microgrid Controller

A control system for a microgrid was developed for use at the KaiserPermanente Richmond Medial Center (KPRMC). The microgrid controller wasdeveloped by the partnership of the University of California San Diego(UCSD), OSISoft and Florida State University (FSU) Center for AdvancedPower Systems (CAPS) team using Virtual Microgrid (VM) Real-Time DigitalSimulator (RTDS) test at FSU CAPS. This development of the microgridcontroller has been executed under the auspices of Charge Bliss, Inc.and funded by the California Energy Commission (EPC-14-080) and matchfunding from various sources. The system included autonomous SoC-gatedand Demand Limit real power control, enables economical (real) powerscheduling to reduce cost of electricity for the KPRMC site. This willbe the de-facto operating mode of the microgrid controller at the KPRMCsite to provide maximum economic benefit for the microgrid at the KPRMCsite and, as such, will be used to validate the long-term performancevalidation of the microgrid controller at the KPRMC site.

1. Overview of Microgrid Controller

For the microgrid development, UCSD is responsible for the developmentof the actual control algorithm, whereas OSISoft is involved in thedevelopment of the software of the control algorithm to be on top of thePI system for performance monitoring and controller configurationparameters in the OSISoft Asset Framework (AF) database.

FIG. 5 illustrates a functional block diagram of an exemplary microgridcontroller 500 applied to a Simplified Dynamic Power Model (SDPM) 510 asused at the KPRMC site. The microgrid controller 500 is configured tocompute real/reactive power demand signal (P·, Q·) for an inverter 106or controllable DER (such as PV 102) to ensure the real/reactive powerpair (P₍, Q₍) at the POI/PCC 112 tracks or follows a specifiedreal/reactive power reference pair (P_(#), Q_(#)). Straight arrows/linesindicate data or information flow for the microgrid controller 500.

As shown in FIG. 5, the microgrid controller 500 consists of four maincomponents, a decoupling power feedback (DPF) module 502, a rate limiteroperation (RLO) module 504, a charge monitoring and control (CMC) module506, and a safe output shutdown (SOS) module 508. The DPF 502 implementsthe control algorithm to allow for decoupled/reactive feedback control.The RLO 504 functions to compute rate limited real/reactive powerreference signals with the possibility to allow for independentlyspecified external real/reactive power reference pair (P_(#), Q_(#)).The CMC 506 functions to adjust real power reference signals to controlthe SoC of the BESS 104. The SOS 508 enables operator and automaticshutdown of the microgrid controller 500 in case of islanding switching.

The four distinctive components of the microgrid controller 500 aredesigned to facilitate safe islanding switching of the microgridcontroller 500 supporting two main features. The first feature is thedecoupling real/reactive power control at the POI/PCC 112 viasynchrophasor feedback. This feature provides support for the AutomaticDemand Response (ADR) at the KPRMC site to track (rate limited) real andreactive power reference signals specified by an Independent SystemOperator (CAISO). The second main feature is the SoC-gated control ofthe BESS 104 and real power demand limitation at the POI/PCC 112 viasynchrophasor feedback. This feature provides support to maximize theeconomic benefit of the microgrid controller 500 for the KPRMC site bymodulating power flow at the POI/PCC 112 according to daily time-varyingand seasonal Time-of-Use pricing and daily time-varying and seasonalDemand Limit pricing accrued over a monthly billing cycle.

The microgrid controller 500 will support the specification ofreal/reactive (P_(#), Q_(#)) power flow reference signals via either anindependent system operator (CA)ISO or autonomously computed (ramp ratelimited) real/reactive (P_(#), Q_(#)) power flow reference signals basedon economic incentives to minimize the cost of electric energy anddemand charges for the microgrid at the KPRMC. A more detailedexplanation of the features follows, providing the motivation of thedesign and choice of the proposed full functional diagram of themicrogrid controller 500 shown in FIG. 5.

2. Use of Synchrophasor Data for Feedback

Synchronized voltage and current phasor may be measured with a PhasorMeasurement Unit (PMU) and provide real-time and high frequent updateson the electrical properties and real/reactive power flow of themicrogrid 100 at the PCC/POI 112. The use of synchrophasor data forfeedback has been integral part of the development of the microgridcontroller 500 as synchrophasor data provides valuable information tocontrol power flow at the PCC/POI 112 using feedback.

Unanticipated real and reactive power fluctuations at the PCC/POI 112due to load variations or intermittency in PV power production may bemeasured in real-time by synchrophasor data. As a result, thoseunanticipated real/reactive power fluctuations may be compensated inreal-time instead of trying to predict and plan for those loadfluctuations.

The voltage phasor v and a current phasor i are related via Ohm's lawv=gi, where g denotes the (Thevenin equivalent) complex impedance of theelectric AC network that related the voltage and current. Typically, theimpedance is a dynamic filter, that could be represented by a transferfunction g(s) in the Laplace variable s and the complex impedance g isfound by evaluating g(s) at s=jω for ω=2πf where f=60 Hz is thefundamental AC frequency. As a result, g=g(jω) will be a complex numberg=Ge⁷⁸⁹ whereG=|g(jω)|,φ_(g) =∠g(jω)

With a given voltage phasor v=Ve⁷⁸@ driving an electric network, theresulting steady state current phasor i=Ie⁷⁸Bw may be computed from theimpedance by complex number division and results into i=Ie⁷⁸B, whereI=G ^(V),−φ_(C)=φ_(D)−φusing the polar coordinate representation of the phasors and theimpedance g=Ge⁷⁸⁹. From this analysis it is clear that the angledifference φ_(D)−φ_(C) between the voltage and current phasor iscompletely determined by the phase angle φ₌ of the impedance at thefundamental AC frequency.

Consequently, real and reactive power flow for a balanced 3 phase ACelectric network defined by the Positive SequenceP=3VI cos(φ_(D)−φ_(C))=3VI cos Jφ=KQ=3VI sin(φ_(D)−φ_(C))=3VI sin Jφ=Kare completely determined by the impedance g. Moreover, it can be seenthat the real P and reactive power Q are inherently coupled due to Ohm'slaw by the property of the Thevenin equivalent complex impedance g ofthe electric network that relates the voltage and current.

What is also interesting to observe from this analysis is that thecharacteristics of the Thevenin equivalent complex impedance g at thePoint of Interest (POI) of an electric network can be altered if thereal P and reactive Q power flow could be controlled independently fromwithin that electric network. For example, ensuring that the reactivepower flow Q=0, ensures that φ==0 or φ==π rad, making g=G or g=−G apurely resistive load. The possibility to make g=−G with Q=0 and P<0ensures negative real power flow for energy “storage” instead of energy“delivery”. The concept of independently controlling real and reactivepower has been recognized by Charles Wells and OSIsoft who were broughtto this project to enable decoupled power control. The decoupled powercontrol will enable independent power flow specification for both realand reactive power at the PCC/POI 112 of the microgrid 100.

3. Use of Dynamic Models Real and Reactive Power Flow

To be able to tune and guarantee the stable operation of a synchrophasordata feedback-based microgrid controller 500, real/reactive powercontrol at the PCC/POI 112 is first modelled in a dynamic model. TheSimplified Dynamic Power Model (SDPM) 510 models both the dynamicbehavior of power flow and the dynamic coupling between (P·, Q·) demandsignals for the inverter 106 and the (P₍, Q₍) power flow pair at thePOI, as illustrated in FIG. 6.

FIG. 6 illustrates one embodiment of a system 600 used at the KPRMCsite. FIG. 6 shows that the SDPM 510 models the dynamics from a (smart)inverter 106 real/reactive power demand signal (P·, Q·) to real/reactivepower flow pair (P₍, Q₍) at the POI/PCC 112 to the main utility grid 110and measured by a Phasor Measurement Unit (PMU) 602. Actual power flowis indicated by hashed arrows/lines, whereas straight arrows/linesindicate data or information flow.

FIG. 6 shows the concept for the system 600 used at the KPRMC sitewherein the one of the DERs (such as PV 102) is replaced by thePrinceton Power Systems (PPS) BIGI inverter 604 that has 2 DCconnections. Actual power flow is indicated by hashed arrows/lines,whereas straight arrows/lines indicate data or information flow. One DCconnection is used for the directional (real) power flow from the PV102, whereas the other DC connection is used for the bi-directional(real) power flow to the Battery Energy Storage System (BESS) 104.

Following the specification of the PSS BIGI inverter 604, real/reactivepower demand signals indicated by the pair (P·, Q·) are specified to thePSS BIGI inverter 604 and (the sum of the) DC power coming from the PV102 and the BESS 104 is used to modulate real/reactive power indicatedby the pair (P, Q) according to the specification of real/reactive powerdemand pair (P·, Q·). FIG. 6 also indicates the use of a PMU 602 tomeasure the resulting real/reactive power flow pair (P₍, Q₍) at thePOI/PCC 112 of the microgrid 100. It is important to recognize that realand reactive power flow (P, Q) (P·, Q·) satisfied locally at the PSSBIGI terminals does not guarantee that these exact same independentlyspecified power flow pair (P₍, Q₍) is obtained at the POI terminals ofthe microgrid 100. The SDPM 510 indicated on the right in FIG. 6 isintended to capture the dynamics of the power flow from thereal/reactive power demand pair (P·, Q·) to the real/reactive powerPOI/PCC pair (P₍, Q₍).

In addition, the SDPM 510 also incorporates measurements of the State ofCharge (SoC) of the BESS 104, the AC real power P created by the PPSBIGI inverter 604 and PV or Solar power P_(N) used by the PSS BIGIinverter 604. These measurements may be provided by the PSS BIGIinverter, but the AC real power measurement P can also be obtainedindependently with an additional PMU installed on the PPS BIGI inverterterminals. Although these additional measurements will not be used inthe actual decoupling real/reactive power control, these measurementsare important to guarantee safe operation of the controller 500 andmonitoring of the SoC to ensure the BESS 104 is not over- orundercharged during decoupling power control operation.

It should be pointed out that the terminology and nature of the SDPM 510is to capture only the dynamic nature of the power flow from a DERcommand signal (real/reactive power demand for an inverter) to the powerflow at the POI/PCC 112 of the microgrid. The simplified nature of themodel indicates that the model does not capture each and every dynamicelement (conductors, capacitors, transformers, etc.) in the microgrid tobe controlled, but instead focusses on the dynamic aspects relevant forpower flow control only.

For control design purposes, the dynamics of power flow in the SDPM 510is denoted by a 2×2 multivariable transfer function R(s) and is given byOQP(₍(s)P=QRRTSSS((ss))RRTTST((ss))U QQP″((ss))U(s)with the entries

R_(SS)(s) for real power P·(s) demand at the inverter to real powerP₍(s) flow result at the POI

R_(TT)(s) for reactive power Q·(s) demand at the inverter to reactivepower Q((s) flow result at the POI.

R_(TS)(s) for real power P·(s) demand at the inverter to reactive powerQ((s) flow coupling at the POI.

R_(ST)(s) for reactive power Q·(s) demand at the inverter to real powerP₍(s) flow coupling at the POI.

For modeling purposes, it is assumed that the entries of 2×2multivariable model R(s) is given by rational transfer functions

${num}\begin{bmatrix}{{\,_{ss}(s)}\mspace{14mu}{{num}_{ST}(s)}} \\{{{QRR}_{TS}{{SS}\left( ({ss}) \right)}{{RRST}_{TT}\left( ({ss}) \right)}U} = {❘{❘{❘{{{{numden}_{TSS}\left( ({ss}) \right)}{{numden}_{TTS}\left( ({ss}) \right)}}❘{❘❘}}}}}} \\{{{den}_{T}(s)}\mspace{14mu}{{den}_{T}(s)}}\end{bmatrix}$and formulated as a ratio of numerator and denominator polynomials inthe Laplace variable s.

The individual rational transfer function models are estimated byperforming experiments on the (virtual) microgrid and collecting timedomain data the real/reactive (P·, Q·) power demand signals for theinverter 106 and the real/reactive(P₍, Q₍) power flow pair at the POI.The time domain data of “input” (P·, Q·) and “output” (P₍, Q₍) signalsare used to estimate the parameters of the numerator and denominatorcoefficients of the rational transfer function models in eithercontinuous- or discrete-time. For the parameter estimation, the stepresponse-based realization methods developed at UCSD or well-knownPrediction Error Minimization (PEM) methods developed by Ljung (1999)are used.

The advantage of the data-based modeling approach is that models aredirectly formulated based on experimental data instead of complicatedcircuit models that would (a) increase model complexity and (b) increasemodel uncertainty due to the lack of a complete set of parameterinformation for the circuit model.

4. Decoupling Real/Reactive Power Control Via Synchrophasor Feedback

The idea of independently controlling the real and reactive power flowis well established and common practice in modern microgrids. FIG. 7 isa schematic diagram of one embodiment of a microgrid 700 which includesa DER 702 subject to a real/reactive power (P·, Q·) demand requirementin the microgrid, producing real/reactive power pair (P, Q) at theterminals of the DER 702 and a real/reactive power pair (P₍, Q₍) at thePoint of Interest (POI) or Point of Common Coupling (PCC) 704 to themain utility grid 706. As illustrated in FIG. 6, controlling real andreactive power flow is performed by introducing the DER 702 into theelectric network 708 for which real P and reactive Q power flow demandsmay be specified independently. Clearly, modern (smart) inverters thatmay be part of the DER 702 may accept such independent real and reactive(P, Q) power pair demands and are used for the practical implementationof this idea to control power flow at the PCC 704 of the microgrid 700to the main grid 706.

As mentioned earlier, a DER 702 implemented via a (smart) inverter onlymakes sure the independent real and reactive power flow demand denotedby (P·, Q·) is satisfied locally at the inverter terminals via (P, Q)and typically does not guarantee that these exact same independentlyspecified power flow pair (P₍, Q₍) is obtained at the POI terminals ofthe electric network 708. It is important to guarantee a specified (P₍,Q₍) pair at the POI terminals, as it is the point of interaction withthe utility where the Thevenin equivalent complex impedance needs bealtered.

The Decoupling Power Feedback (DPF) module 502 in the microgridcontroller 500 uses the Simplified Dynamic Power Model (SDPM) 510 R(s)to formulate a decoupling filter to decouple the power flow. Once thepower flow is decoupled, standard Proportional, Integral and Derivative(PID) control algorithms are used to provide real-time feedback of the(P₍, Q₍) power flow pair at the POI. Details on the computation andtuning of the decoupling filter and the PID control algorithms is asfollows.

The decoupling filter, denoted by D(s), is also a 2×2 multivariabletransfer function that is essential for: 1) The decoupling ofreal/reactive (P₍, Q₍) power flow pair at the POI; and 2) The separatedesign of real power feedback controllers Cs(s) and a reactive powerfeedback controller C_(T)(s) to control and track real/reactive (P_(#),Q_(#)) power flow reference signals at the POI. The combination of 2×2multivariable decoupling filter D(s) given byD(s)=QDDbbcb((ss))DDbccc((ss))Uand the two independent real power feedback controllers C_(S)(s) and areactive power feedback controller C_(T)(s) construct the controlalgorithm in the DPF module 510.

The control algorithm in the DPF module 510 operates on the 2×2multivariable power flow transfer function R(s) from inverter demand toPOI as depicted earlier in FIG. 7. It should be noted that the controlalgorithm in the DPF module 510 aims at decoupling the real/reactive(P₍, Q₍) power flow pair at the POI. It is achieved by the separatedesign of the 2×2 multivariable decoupling filter D(s) and thedecoupling design of PID controllers C_(S)(s) and C_(T)(s) respectivelyfor real and reactive power flow tracking.

Due this decoupling design, the controller 500 will achieve thedecoupling of real and reactive (P₍, Q₍) power flow pair at the POI ofthe microgrid. This means that any unanticipated real or reactive powerflow variations created within the microgrid (conceptually characterizedas “disturbances”) are independently controlled and mitigated by thecontrol algorithm in the DPF module 510. In addition, the controller 500provides independent tracking of real/reactive (P_(#), Q_(#)) power flowreference signals at the POI. This means that an Independent SystemOperator (such as CAISO) may specify these real/reactive (P_(#), Q_(#))power flow reference signals to accomplish a desired real/reactive powerflow over the POI of the microgrid.

The independent tracking is especially important to achieve to desiredfeature to guarantee a specified (P₍, Q₍) power flow pair at the POIterminals, as it is only at the POI where the Thevenin equivalentcomplex impedance g of the microgrid needs be altered. The microgridcontroller 500 will support the specification of real/reactive (P_(#),Q_(#)) power flow reference signals via either an independent systemoperator (CA)ISO or an autonomously computed (ramp-rate limited)real/reactive (P_(#), Q_(#)) power flow reference signals based oneconomic incentives to minimize the cost of electric energy for themicrogrid.

The information on the 2×2 multivariable transfer function R(s),modeling the power flow from inverter demand (P·, Q·) to POI power flow(P₍, Q₍), may be used to formulate a decoupling filterD(s)=QDDbbcb((ss))DDbccc((ss))U=d(1s)Q−numnumTTTS((ss))−numnumSSST((ss))Uwhere d(s) is a user-chosen common denominator polynomial to ensure the2×2× multivariable decoupling filter D(s) is a (strictly) propertransfer function. In case of a static (non-dynamic) decoupling gain,the denominator d(s) may be chosen as d(s)=1, but in general thepolynomial is used to implement some form of low pass filtering in the2×2 multivariable decoupling power feedback (MDPF) controller. With theabove definition of the decoupling filter D(s) it is easy to verify thatthe decoupling filter modifies the 2×2 coupled real/reactive power flowdynamics R(s) into a 2×2 decoupled real/reactive power flow dynamicsRe(s) given byRe(s)=R(s)D(s)=O ^(Rebb)0^((s)) Re _(cc) ⁰(s)Pwhere Re_(bb)(s) and Re_(cc)(s) are modified versions of R_(bb)(s) andR_(cc)(s) due to the decoupling filter D(s) and its common denominatorpolynomial d(s). Clearly, Re(s)=R(s)D(s) is decoupled due to the zerooff-diagonal terms and once D(s) is chosen, the transfer functionsRe_(bb)(s) and Re_(cc)(s) are known and the decoupled controllers Cs(s)and C_(T)(s) for real/reactive power flow control and tracking may bedesigned.

The controllers Cs(s) and C_(T)(s) are given by standard PID controllersand given by the transfer functionsCS(s)=Kgg+Kigs+KCg/sCT(s)=Kgk+Kiks+KCk/s,where the controller parameters for the proportional gain K_(g),derivative gain K_(i) and integral gain K_(C) are tuned on the basis ofthe models Re_(bb)(s) and Re_(cc)(s) obtained via the decoupledreal/reactive power dynamics Re(s). The actual implementation of the PIDcontrollers is done is in discrete time and incorporates anti-windupcapabilities to avoid integral wind-up due to amplitude and rateconstraints on the inverter power demand signals (P·, Q·).AlgorithmC(s)=QCCbbcb((ss))CCbccc((ss))U=QDDbbcb((ss))DDccbc((ss))UQCSO(s)CTO(s)Uas stated before. The controller is designed via the separate design ofD(s), Cs(s) and C_(T)(s) based on the coupled real/reactive power flowdynamics R(s).

It should be noted that the final multivariable decoupling powerfeedback (MDPF) control algorithm is a true 2×2 multivariable controlalgorithm.

5. State of Charge Gated Control Via Real Power Modulation

The PPS BIGI inverter 604 is limited to 250 kVA total AC power output.This means that real and/or reactive power demand (P·, Q·) signals tothe inverter must be limited by1 P _(u) ² +Q ²≤250·kVAto ensure the control algorithm in the DPF module 502 does not saturatethe inverter power output. Furthermore, large real and/or reactive powerdemand (P·, Q·) signals may also drain or overcharge the battery. As aconsequence, the microgrid controller 500 must be given real/reactivepower reference signals (P_(#), Q_(#)) that will incorporate provisionsto avoid inverter 106 output saturation and/or BESS 104 over- andunder-charging.

The Rate Limiter Operation (RLO) 504 module computes (internal)real/reactive power reference signals (P_(Cqr), Q_(Cqr)) based on a ratelimited version of the uncontrolled real/reactive power signals at thePOI/PCC 112. FIG. 8 is a block diagram of one embodiment of RLO module504. The RLO module 504 uses the real/reactive POI/PCC power JP₍, Q₍Kand the real/reactive demand power (P·, Q·) to formulate a powerdisturbance estimator for the (autonomous) computation of ramp-ratelimited power reference signals (P_(Cqr), Q_(Cqr)) adjusted by anexternal specified real/reactive power reference (P_(#), Q_(#)).Additional binary signal HP (Hold Power) and EC (Enable Control) areused to adjust ramp-rate limits and/or latch power signals for aconstant real/reactive power reference.

The RLO module 504 computes rate limited power signals as (internal)real/reactive power reference signals (PCqr, QCqr). The use of ratelimited power signals as (internal) real/reactive power referencesignals (P_(Cqr), Q_(Cqr)) ensures that volatile power fluctuations atthe POI/PCC 112 are being ignored in the reference (P_(Cqr), Q_(Cqr))and reduced by the DPF module 502 in the microgrid controller 500. Theuse of the uncontrolled real/reactive power signals at the POI/PCC 112to compute those rate limited power signals as (internal) real/reactivepower reference signals (P_(Cqr), Q_(Cqr)) ensures that the (internal)real/reactive power reference signals (P_(Cqr), Q_(Cqr)) will be closeto the uncontrolled real/reactive power signals at the POI/PCC 112,thereby reducing and minimizing the potential power demand signals (P·,Q·) for the PSS BIGI inverter 604 to avoid saturation.

As the microgrid controller 500 is controlling the real/reactive powersignals (P₍, Q₍) at the POI/PCC 112, the uncontrolled real/reactivepower signals at the POI/PCC become unavailable. The RLO module 500solves this problem by reconstructing the uncontrolled real/reactivepower signals at the POI/PCC 112 via a disturbance estimator, using thesame SDPM R(s) as defined earlier in FIG. 5.

Although the RLO module 504 as shown in FIG. 5 does not indicate the useof the demand signals (P·, Q·) to minimize the number of lines drawn inthe figure, the RLO module 504 uses the SDPM 510 R(s) to formulate adisturbance estimator by reconstructing the uncontrolled real/reactivepower signals at the POI/PCC 112. It may be observed from FIG. 8 thatthe RLO module 504 uses the real/reactive power demand signals (P·, Q·)for the inverter 106 along with the SDPM 510 R(s) to estimate theuncontrolled real/reactive power signals (P₍, Q₍), which in turn is usedto determine the (internal) real/reactive power reference signals(P_(Cqr), Q_(Cqr)) based on rate limited version of the estimateduncontrolled real/reactive power signals (P₍, Q₍).

In addition, the RLO module 504 allows for the use of externallyspecified power reference signal (P_(#), Q_(#)) that are added to eitherthe estimated uncontrolled real/reactive power signals (P₍, Q₍) or thelatched value of controlled real/reactive power signals (P₍, Q₍) at thePOI/PCC 112. Latching may be enabled when a user-specified binary HoldPower (HP) is set to true (HP=1), whereas a user-specified binary EnableControl (EC) may be used to turn on/off the controller, subject to slewrate limiters.

To ensure the control algorithm in the DPF module 502 does not drain orovercharge the BESS 104, the microgrid controller 500 also incorporatesprovisions to adjust the (internal) real power reference signal P_(Cqr)on the basis of the State of Charge (SoC) data 112 from the BESS 104 orbatteries connected to the inverter 106 used for control. The ChargeMonitoring and Control (CMC) module 508 compares the externallyspecified SoC reference signal SoC_(#) with SoC data 120 from the BESS104 to adjust the real power reference signal P_(Cqr) using aProportional Integral (PI) control algorithm.Cvwx(s)=Kgvwx+KCvwx/sto ensure the SoC data 120 from the BESS 104 tracks the externally SoCreference signal SoC_(#).

The implication of the SoC monitoring and control algorithm implementedin the CMC module 508 is that the (internal) real power reference signalP_(Cqr) may be adjusted up/down, depending on the SoC of the BESS 104.It should be pointed out that SoC adjustments are much slower indynamics than (real) power adjustment and the adjustment of the realpower reference signal P_(Cqr) will be of much lower (control) bandwidththan the power adjustments needed for the decoupling real/reactive powercontrol.

6. SoC-Gated and POI/PCC Power Limitation Via (Real) Power Modulation

Combining the MDPF control algorithm is a true 2×2 multivariable controlalgorithmC(s)=QCCbbcb((ss))CCbccc((ss))U=QDDbbcb((ss))DDbccc((ss))UQCSO(s)CTO(s)Uas stated before with the CMC module 508 control algorithmCvwx(s)=Kgvwx+KCvwx/sensure the SoC data 120 from the BESS 104 tracks the externally SoCreference signal SoC_(#) and any real/reactive power flow (P₍, Q₍) pairat the POI terminals does not exceed a specific limit. Such a limitP((t)≤Piz{|qi

The limit is particularly important for the real power P₍(t) at anygiven time t during the day and the monthly billing cycle. EnsuringP₍(t)≤P_(iz{|qi) limits the real power demand to P_(iz{|qi), which isimportant to note thatPiz{|qi=∈maxP(t)is computed over a monthly billing cycle, so that P₍(t)≤P_(iz{|qi) mustbe satisfied over each and every billing cycle.

The combined MDPF and CMC module 508 control algorithm implemented inthe microgrid controller 500 is depicted schematically in FIG. 9. Asshown in FIG. 9, the microgrid controller 500 controls the PrincetonPower Systems (PPS) BIGI inverter 604 at the KPRMC site by combiningboth the MDPF control algorithm and the CMC module 508 controlalgorithm.

B. De-Risking and Testing Procedures of the Microgrid Controller

1. Overview of Power Simulation Model

The proposed microgrid controller with the MDPF control algorithm istested using real-time controller hardware in the loop (CHIL) simulationby the Nhu Energy, Inc. and Florida State University (FSU) Center forAdvanced Power Systems (CAPS) team. Test results of the microgridcontrol are running at the Synchrophasor Grid Monitoring and Automation(SyGMA) lab at UCSD, communicating in real-time over a secure VPN to theRTDS system at FSU CAPS—demonstrating real time control from east coastto west coast before implementing the microgrid controller at the KPMRCsite.

Specifically, the KPRMC electrical system is simulated on a Real-TimeDigital Simulator (RTDS) system at FSU-CAPS and the controller is testedby interacting in real-time with the simulated microgrid. The resultsfrom the CHIL experiments verify the capabilities of the proposedmicrogrid controller. For example, the CHIL experiments show decouplingreal and reactive power feedback control to maintain an arbitraryspecified Thevenin equivalent complex impedance g at the POI of anelectric network. The CHIL is primarily used for de-risking anddevelopment of controls for planned hardware additions to the KPRMCelectrical system including PV and a BESS or batteries.

FIG. 10 is a high-level illustration of the modelled KPRMC microgrid1000 in RTDS with Phasor Measurement Units (PMU) 1002 and controllableinverter 1004. The microgrid model 1000 has loads which may becategorized as nonemergency 1006 and emergency 1008. The emergency loads1008 draw much less power than the non-emergency loads 1006 and maytherefore be powered solely by the planned hardware installation. Theemergency and non-emergency loads each consist of a constantimpedance-current-power (ZIP) load 1010 and two induction machines 1012.The grid interconnection 1014 is modeled using an infinite source andtransformer equivalent impedance. The modeled additions to the microgrid1000 include 6 PMUs 1002, a PV array 1016, an inverter 1004, and abattery 1018. The inverter and battery storage are rated at 250 kW/250kVar and 250 kW/1 MWh, respectively.

TCP/IP Modbus and C37.118 data communication is implemented in thereal-time simulation. The model includes 6 PMUs 1002 that send C37.118messages providing measurements throughout the microgrid 1000. TheC37.118 interface is used to communicate Phasor Measurement Unit (PMU)data which include 3-phase voltage phasors (voltage amplitude andangle), current phasors (current amplitude and angle), and positivesequence 3-phase real and reactive power. PMU 1 is located at the Pointof Common Coupling or PCC for observing overall power flow. PMUs 2/3 arelocated at the AC connection of the Emergency Load (EL) for observingpotential EL power flow. PMUs 4/5 are located at the Automatic TransferSwitch, used to emulate the islanding condition of the 250 kW PrincetonPower Systems (PPS) Inverter with the emergency loads. PMU 6 is locatedat the AC connection of the 250 kW Princeton Power Systems (PPS)Inverter for observing PPS power flow.

The simulated inverter 1004 provides a Modbus TCP/IP interface, which isthe communication channel for controlling real and reactive power andinformation including battery SoC and PV power.

The microgrid model 1000 and associated HIL components are used tocreate various environments for the testing the developed controls.These environments are intended be meaningful representations of theactual system in order to characterize the effect of the controls on theactual system (when deployed). A variety of environments are availableand described below to verify and refine the developed control.

1. Parameterized scenarios including peak power demands as seen at theutility interface (POCC). Selected scenario parameters are:

a. Time of day and demand profile: normal demand patterns, large loadpick-up, loss of large load;

b. Solar PV generation profile; and

2. System under closed-loop control with PMU failures

-   -   a. Data communications        -   i. Prolonged network outage intended to simulate an            unresponsive device or unplugging a network cable and            plugging it back        -   ii. Lost packets        -   iii. Packets delayed        -   iv. iv. Packets reordered    -   b. Sensor anomalies intended to represent malfunctioning (or        poor-quality sensors).    -   c. Measurements from voltage and current sensors are modified        (e.g., 2% of actual value).        3. System under closed loop control with either failure of the        inverter to respond to control commands or saturation of the        inverter P or Q at high or low limits.    -   a. Prolonged network outage intended to simulate an unresponsive        device or a unplugging a network cable and plugging it back    -   b. Unresponsive commands        -   i. Active Power (input)        -   ii. Reactive Power (input)    -   c. Incorrect information        -   i. Battery state of charge (output)        -   ii. PV power generation (output)

2. Overview of Controller Hardware-in-the-Loop Testing

The Controller Hardware-in-the-Loop (CHIL) setup includes the real-timesimulated microgrid (also referred to as virtual microgrid), controller,field measurements, and interfacing (controller, simulation, sensing,and converter). The controls developed by and operated at the UCSD areremotely interfaced to the real-time simulated model of the KPRMCmicrogrid 1000 to test operational and performance characteristics. Themajor benefit of the CHIL-based testing of the microgrid controls is thepossibility to reduce the risks involved in deploying new means ofcontrolling and operating distributed energy resources. The developedcontrols may be evaluated for stability and performance beforeinstallation and operation within the actual system.

FIG. 11 illustrates a communication setup of the CHIL testbed 1000 witha microgrid controller 1102 located at UCSD and a microgrid simulator1104 at FSU-CAPS communicating in real-time over the Internet. Themicrogrid control algorithm (controller) 1102 communicates with the CHILtestbed over a virtual private network (VPN) 1106. The VPN provides aninterface that allows the controller 1102, PMUs 1002, and inverter 1004to communicate with the illusion of being on the same local datacommunications network. Simulation data from the CHIL testbed iscommunicated to the controller 1102 via TCP/IP at the rate of 10 Hz. Thecommunicated data items are shown in Table 1 below. PMU communicationadheres to the IEEE C37.118 standard, which is the common IEEE standardfor PMUs in power systems and inverter communication follows the ModbusTCP/IP protocol.

TABLE 1 COMMUNICATED DATA IN THE CONTROLLER HIL TEST SETUP Data From ToComm. Protocol Active and reactive PMUs 1-6 Controller IEEE C37.118power at 6 points Voltage, current, and PMUs 1-6 Controller IEEE C37.118frequency at 6 points Battery SoC Inverter Controller Modbus PVGeneration Inverter Controller Modbus Inverter active and re- ControllerInverter Modbus active power reference

3. The Open-Loop Test Results

The first test that is performed is “open-loop” or “uncontrolled”microgrid test to estimate the dynamics of individual rational transferfunction models for deriving the Simplified Dynamic Power Model (SDPM)510 R(s) indicated earlier in FIG. 5 and also used in the RLO module 504of FIG. 8. The transfer functions in the SDPM 510 R(s) are estimated byperforming experiments on the (virtual) microgrid and collecting timedomain data the real/reactive (P·, Q·) power demand signals for theinverter 1004 and the real/reactive (P₍, Q₍) power flow pair at thePOI/PCC 1014. The time domain data of “input” (P·, Q·) and “output” (P₍,Q₍) signals are used to estimate the parameters of the numerator anddenominator coefficients of the rational transfer function models ineither continuous- or discrete-time. For the parameter estimation, thestep response-based realization methods developed at UCSD or PredictionError Minimization (PEM) methods developed by Ljung (1999) are used.

The open-loop test consists of small step input signals to both the realand reactive power reference signals of the inverter 1004. Theperiodicity of the signals is chosen such that power may settle withineach real or reactive power step applied to the (Virtual) microgrid1000. For performing the test, input/output (IO) modules are developedwith the following functionality: 1) a C37.118 read interface isdeveloped to run under Matlab Simulink to gather experimental data setby PMUs 1002 in the microgrid; and 2) a Modbus master/slave interface isdeveloped to run under Matlab Simulink to send power reference signalsto user-specified Modbus registers over TCP/IP.

Real-time measurements of both real- and reactive power flows providedby the PMUs 1002 are used to formulate the dynamic model R(s) and usedto tune and test the feedback controller on the Simplified Dynamic PowerModel (SDPM) 510 R(s).

The control signals use the Modbus TCP/IP protocol to send active andreactive power reference commands to the simulated inverter 1004. ThePPS BIGI inverter accepts 604 real/reactive power demand signals (P·,Q·) at a rate of only 1 sample/second with an additional delay of 1second. The simulated inverter 1004 of the virtual microgrid model 1000may accept fast update rates of 10 samples/second over the internet toFSU-CAPS (east coast) from the SyGMA lab at UCSD (west coast). Themaximum rate of real/reactive power demand signals (P·, Q·) is primarilylimited by the speed of the network connection between FSU and UCSD.

FIG. 12 illustrates open-loop test data, measuring real and reactivepower flow (P₍, Q₍) “output” signals (solid lines) due to real andreactive power flow “input” (P·, Q·) demand signals (dashed lines) atthe POI. It may be observed from the open-loop test data that real andreactive power JP₍, Q₍K at the POI changes due to real and reactive (P·,Q·) demand signals, but also (small) coupling may be observed in theJP₍, Q₍K signals. Furthermore, the RTDS simulation shows (uncontrolled)large variations of the real and reactive power JP₍, Q₍K at the POIcausing real and reactive power control to drift and change. The controlalgorithm of the microgrid controller 1102 aims to reduce these powerfluctuations. As a final note, it should be observed that the simulationmodel has not been fully validated against high resolution data from theactual KPRMC microgrid 1000, but the approach illustrates that dynamicsand coupling between real and reactive power JP₍, Q₍K at the POI may bemodelled with step-based changes on the real and reactive (P·, Q·)demand signals that may be replicated on the actual KPRMC microgrid.

4. Closed-Loop Test: Externally Specified Real Power Reference

Based on the “open-loop” test data, an open-loop model of the (coupling)power flow in the microgrid model 1000 simulated by the RTDS. The modelwas used to formulate a decoupling filter D(s) as described above andtune the PID controllers C_(S)(s) and C_(T)(s) for real/reactive powerflow control and tracking. The results of tracking an externallyspecified real power flow reference P_(#) over a short time interval (2minutes) is depicted in FIG. 13. FIG. 13 is a demonstration of realpower tracking, where an Independent System Operator (CAISO) externallyspecified real power reference signal of 1.3 MW (indicated byhashed-lines) is followed (tracked) for 2 minutes. In this test only thereal power is subjected to a fixed reference signal, while reactivepower is allowed to change.

When the control is started, the real power demand of the inverter 1004jumps up bounded by rate constraints. When the control is stopped, theSOS module 508 forces the control to ramp down to zero subject to itsregular ramp rate limitation and demonstrating a safe controllershutdown. The results depicted in FIG. 13 show the powerful effects ofthe microgrid controller 1102: the real power may be held at auser-specified value for a short time, only dependent on the availableSoC of the battery. It should be pointed out that these results wereobtained by running the RTDS (Virtual Grid) model at FSU (east coast),while running the control algorithm at the SyGMA lab at UCSD (westcoast). All this was done at 10 Hz sampling and shows that thecontroller testing and tuning may be done even over large distances.

5. Closed-Loop Test: Decoupling Real/Reactive Power Control

Demonstration of the independent real/reactive power controlcapabilities of the microgrid controller is illustrated in FIG. 14. Inthese experiments an externally specified step-wise changing real powerreference signal and a constant reactive power reference signal are usedto demonstrate the decoupled real/reactive power tracking capabilitiesof the microgrid controller 1000. FIG. 14 demonstrates decoupled realand reactive power tracking, where an Independent System Operator(CAISO) externally specified+/−100 kW step-wise changing real powerreference signal and a constant reactive power reference signal arefollowed (tracked) whenever the binary signal Hold Power (HP) is set totrue (HP=1). The control is started when Enable Control (EC) is set totrue (EC=1), starting the microgrid controller in the autonomous ramprate mode. The control is stopped when Enable Ramp (ER) is set to true(ER=1), where the SOS module forces the control to ramp down to zerosubject to its regular ramp rate limitation and demonstrating a safecontroller shutdown.

The independent real/reactive power control capabilities of themicrogrid controller illustrated in FIG. 14 demonstrate the powerfulfeature of the microgrid controller 1102: to be able to follow or trackreal and reactive power demands at the POI/PCC independently. Althoughthese features are important for a microgrid, the ability toindependently track real and reactive power is limited by the inverter(actuator) saturation, but also by the amount of energy available. Assuch, it is important to also maintain and control the SoC of the BESS1018 to be able to maintain the control authority to track and regulatereal power.

The capabilities to be able to follow or track real and reactive powerdemands at the POI/PCC independently despite a large discrepancy in theSoC of the BESS 1018 is illustrated in FIG. 15. FIG. 15 demonstrates(decoupled) real power tracking, where an Independent System Operator(CAISO) externally specified+/−100 kW step-wise changing real powerreference signal and the BESS 1018 started out at a 80% SoC with large(real) power fluctuations at the PCC/POI of the microgrid 1000. In theseexperiments the BESS 104 started out with a relatively large SoC levelof almost 80%, whereas significant real/reactive power fluctuations atthe POI/PCC were present due to periodic load switching in the microgrid1000.

Similar to the results shown in FIG. 14, the power reference signal isfollowed (tracked) in FIG. 15, whenever the binary signal Hold Power(HP) is set to true (HP=1). The control is started when Enable Control(EC) is set to true (EC=1), starting the microgrid controller in theautonomous ramp rate mode. The control is stopped when Enable Ramp (ER)is set to true (ER=1), where the SOS module 508 forces the control toramp down to zero subject to its regular ramp rate limitation anddemonstrating a safe controller shutdown.

The results in FIG. 15 indicate the adjustments the microgrid controller1102 makes to the real power to ensure the BESS 1018 will not beover-charged. As observed in the SoC plot (bottom plot in FIG. 15), thestarting SoC of the battery 1018 is set outside the dead zone band fortest purposes. The controller 1100 is activated at 500 s from when it iscommanded to operate in the autonomous rate limited mode (or also calledadaptive reference mode). However, by this time, since the SoC hasalready grown largely out of limits and passed its absolute limits, theonly priority of the control system becomes SoC recovery until itreaches the safe zone. This is done by operating the inverter 1004 inthe full power mode (subject to ramp rate limitation) and continuesuntil SoC reaches safe zone at around 1000 s. Afterwards, the controller1102 switches back to adaptive reference mode and the power measured atPOI/PCC is able to follow the reference. The reference computed by theadaptive reference computation module is shown by blue in the topfigure. This scenario continues until time 3000˜. The inverter's 1004control input during this period is shown by red in the middle figureand falls within the inverter's power limits. At time 3000 s, thecontroller 1102 is switched from adaptive to manual reference mode,where the controller is able to follow a modulating trapezoidalreference set by the user. The bottom plot shows that the SoC is withinacceptable limits after time 1000 s. As observed in middle plot of FIG.15, the inverter's 1004 control input is barely reaching its limitsafter time 1000 s, which means the reference variations are within theinverter's power control capability. The controller 1102 is finallyswitched off at 4800 s.

7. Closed-Loop Tests: Dynamic Load Switching

Although very good results have been obtained by the CHIL using themicrogrid controller 1102 to track real/reactive power referencesignals, a final test was performed with dynamic load switching. Thedynamic load switching demonstrates the capabilities of the microgridcontroller to reduce power flow disturbances at the POI/PCC caused by(fast) dynamic load changes. The results are illustrated in FIG. 16which demonstrates (decoupled) real power disturbance rejection, wherereal power fluctuations at the POI/PCC are generated by (periodic)on/off switching of fast dynamic loads in the microgrid 1000.

The test results summarized in FIG. 16 are designed to emulate moretransient microgrid events and examine the controller's 1102 ability tocontinue to perform in the presence of transient power fluctuations. Inparticular, the test results in FIG. 16 emulate abrupt load switchingevents and the effect of inverter's 1004 ramp rate limitation and thecommunication delay on the controller's 1102 ability to control thoseevents. The test scenario comprises the microgrid 1000 with its usualtime-varying load demand while an additional 50 kW motor is suddenlyswitched in. The switch-in event causes POI/PCC real power to experiencea sudden jump, however, the controller 1102 should be able to recoverthe previous POI/PCC power level in a timely manner. After successfulrecovery, the 50 kW motor is switched off and a 100 kW motor is switchedin this time. A similar scenario then happens for a 150 kW motor.

The results will depend on the ramp rate limits of the inverter and todemonstrate the control capabilities of the microgrid controller 1102.FIG. 16 shows controlled power for a relatively fast inverter with ramprate of 80 kW/s in the presence of a controller delay of one-time stepand a communication delay of one-time step (0.1 sec at 10 Hz). Themicrogrid controller 1102 performs well with the relatively fastinverter 1004 by quickly reducing the power disturbances. This isapparent in both the POI/PCC power plots (top) and inverter power plots(bottom) in FIG. 16. The microgrid controlled inverter 1004 not onlycorrects the steady state power level but also partly diminishes theeffects of fast power transients that occur during the load switching(apparent in the instantaneous spikes after each event.

C. Implementation of Microgrid Controller and Validation of PMU DataUsing SEL Equipment

1. PMU Locations

To be able to implement the developed microgrid controller on the actualmicrogrid of the KPRMC site, the infrastructure to measure synchrophasordata, import data into a control computer and send control signals tothe PPS BIGI inverter needs to be developed. FIG. 17 is a one-linediagram of the KPRMC site microgrid 1700 showing the PMU 1702 locations.It is clear from FIG. 17 that the PMUs 1702 are located at strategiclocations in the microgrid 1700 and coincide with PMU 1002 locationsused in the RTDS model used to simulate the virtual microgrid 1000. ThePPS BIGI inverter is shown at 1706, the battery system at 1708, and thePV array at 1710.

2. SEL-Based Synchrophasor Platform

Synchrophasor data at the 6 different PMU 1702 locations in the KPRMCmicrogrid 1700 indicated in FIG. 17 are being realized by SEL-2240 Axionbased system, whereas computing power for the controller 1704 is basedon the rack-mounted rugged SEL-3355 computer. An overview of the SELhardware installed in the KPRMC microgrid 1700 is illustrated in FIG.18.

The SEL-2240 Axion is a fully integrated, modular input/output (I/O) andcontrol solution that combines the communications, built-in security,and IEC 61131 logic engine of the SEL RealTime Automation Controller(RTAC) family with a durable suite of I/O modules that providehighspeed, deterministic control performance over an EtherCAT network.Inside the SEL-2240 Axion, the SEL-2241 RTAC Module operates as the CPUfor an SEL-2240 Axion Platform. The SEL2241 RTAC Module interfacesseamlessly with the I/O Modules used to implement the PMU capabilitieson the SEL-2240 Axiom platform.

As indicated in FIG. 18, the PMU capabilities for the SEL-2240 Axiomplatform is provided by the SEL-2245-4 Metering Module that provides a4CT/4PT metering capabilities. Together with the SEL-2241 RTAC Module,they provide an IEEE Certified PMU device, capable of sending IEEEC37.118 communication over TCP/IP at 60 samples/second. To power boththe SEL-2241 RTAC Module and the SEL-2245-4 Metering Module, theSEL-2240 Axiom platform also needs an SEL2243 power coupler. Toaccommodate analog signal communications to the PPS BIGI inverter 1706,one of the SEL-2240 Axiom platforms is also equipped with a SEL-2245-3Analog Output Module. It allows the generation of analog voltage orcurrent (4-20 mA) control signals to be sent to an inverter 1706.

PMU data and control commands are processed by a separate Rack-MountRugged SEL Computer: the SEL-3355. Designed as a server-class computer,the SEL-3355 computer is built to withstand harsh environments inutility substations and industrial control and automation systems. Byeliminating all moving parts, including rotating hard drives and fans,and using error-correcting code (ECC) memory technology, the SEL-3355has over ten times the mean time between failures (MTBF) of typicalindustrial computers.

To enable a cyber secure network, all SEL hardware is copper wired ontofirewall protected local network. The SEL 2240 hardware (PMUs and analogoutput) are all daisy chained on the same Local Area Network andconnected only to the SEL-3355 computer. For hardware redundancy, twoSEL-3355 computers are configured in a High Availability (HA) mode toallow independent (security) patching of each SEL-3355, while allowingthe microgrid controller 1704 to run uninterruptedly.

3. Configuration of the SEL Synchrophasor Platform

The SEL equipment for the KPRMC microgrid 1700 comes in 4 chassis(called SEL-2240) and 1 computer (called SEL-3355). The differentchassis have the modules described herein. Each chassis always has a“power coupler” module (called SEL-2243) that requires 110/240 VAC topower the chassis. 3 out of 4 of the chassis have a “Digital Output”module (called SEL-2244). 1 out of 4 of the chassis has a “AnalogOutput” module (called SEL-2245-3). 1 out of 4 of the chassis has a“RTAC” module (called SEL-2241). Each chassis has at least 1 (orsometimes 2) “4CT/4PT” module (called SEL-2245-4) that requires 3 phasevoltage, 3-phase current and (optional) neutral voltage/current signals.

In the setup for the microgrid 1700 of the KPRMC site, a total of 6“4CT/4PT” modules (or PMUs) distributed over the 4 chassis and each“4CT/4PT” module is configured to act as the actual Phasor MeasurementUnit (PMU) measuring synchronized power flow at different locations inthe KPRMC microgrid 1700. The “Power Coupler”. “Digital Output”, “AnalogOutput” and “PMU or 4CT/4PT” modules are distributed over the 4 chassisaccording to chassis configuration 1900 as illustrated in FIG. 19.

Each “4CT/4PT or PMU” module (called SEL-2245-4) requires 3 phasevoltage, 3-phase current and (optional) neutral voltage/current signalsfor actual measurement of phasors and frequency so that 3 phase powerflow may be calculated. The SEL-2245-4 measurement range for voltage is

VNOM: 300 V

Measurement Range: 5-400V L-N, 9-693 L-L Vac

Fundamental/RMS (UL): 5-300V L-N, 9-520V L-L Vac

Maximum: 600 L-N, 1039 L-L Vac Fundamental/RMS for 10 s

The SEL-2245-4 measurement range for current is:

INOM: 1 A or 5 A (no settings required)

Measurement Range: 0.050-22 A Continuous, 22-100 A Symmetrical for 25 s

Scaling may be adjusted in software in case measured voltage/current isadjusted via CT and PT devices.

4. Validation of Power Data

The Princeton Power System (PPS) includes the Energy ManagementOperating System (EMOS), the BIGI system with the inverter 1706 andbattery charging systems 1708. The external microgrid controller 1704 or“microgrid controller” interfaces with the EMOS via Modbus communicationto both measure SCADA data (related to Solar Power Production andBattery State of Charge) and provide external power demand signals. Theexternal microgrid controller 1704 processes the PMU measurementsgenerated by the SEL equipment to compute the desired external powerdemand signal for the EMOS.

A comprehensive tag list for both the PMU data produced by the SELequipment, the SCADA data produced by the PPS and the power demandsignals to the EMOS is used to map measurements to databased entries inthe OSIsoft PI system. The same mapping is also used in the microgridcontroller 1704 to compute the control signals and both PMU data usingC37.118 protocol and SCADA, control signals via the Modbus Function 23(read/write) protocol are implemented over TCP/IP. The communication ofboth C37.118 and Modbus over TCP/IP allows a controller configuration tobe implemented on the SEL3355 (main SEL control computer) that onlyrequires a standard TCP/IP stack for both data gathering and sendingpower demand commands to the EMOS.

The mapping of the I/O signals of the controller 1704 has been testedextensively with the RTDS system running the KPRMC microgrid model. Thevalidation test results show successful monitoring of both the PCC/POIPMU, the inverter PMU and the inverter Modbus register (read/write)reproduce power data that is consistent with the models as illustratedin FIG. 20. FIG. 20 shows real-time measurements of PCC PMU (PMU1,C37.118), inverter PMU (PMU4, C37.118), Solar Power (PV, Modbusregister) and State of Charge (SoC, Modbus Register) obtained viacommunication to RTDS at FSU while updating the real and reactive powerdemand signals to the PPS inverter 1706. The results show how SoC hasreached a maximum value, limiting negative real power demand signal.

With the inverter 1706 and battery system 1708 properly installed andthe SEL hardware with the PMUs 1702 reliably collecting phasor data 60times a second, a simple inverter step response was carried out at KPRMCsite. The inverter steps response was carried out by sending a 50 kWreal power demand response to the inverter 1706, while the PMUs 1702were collecting the measurements of power flow. Such a step response maybe used to model slew rate, latency and dynamic settling of the powerflow at the PCC at the KPRMC site. A summary of the test results and themodeling efforts to characterize the dynamic behavior of the power flowis illustrated in FIG. 21.

The power data displayed in FIG. 21 is also compared by a simulationproduced by the SDPM 510, denoted earlier by a 2×2 multivariabletransfer function R(s). The blue line in the top figure of FIG. 21refers to the step-wise change in the real power demand signal sent tothe inverter 1706. It may be seen that step wise change was a step of+50 kW and s step of −50 kW. A positive value of the real power demandsignal of 50 kW causes the battery 1708 to be discharged, while anegative value is used for charging of the battery 1708. The green lineis a measurement of the real power flow computed from the 3-phase phasormeasurement of PMU6, located at the AC port of the inverter 1706. It maybe seen that the inverter 1706 exhibits a slew rate limitation and asmall overshoot in power flow. The red line is a dynamic model fitted onthe measured data, modeling the inverter slew rate and dynamic response.Main conclusion from this plot is that the SDPM 510 of the power flow onthe inverter 1706 is able to simulate the measured real power flow verywell. As such, the model is used for off-line tuning of the microgridcontroller 1704 to ensure the controller will work with the anticipatedinverter dynamics.

While measuring and modeling the dynamic response of the inverter 1706for the real power flow, a similar procedure has been carried out forthe reactive power flow as indicated in the bottom plot of FIG. 21 Theblue line refers to the zero-level reactive power demand signal sent tothe inverter 1706. The green line is a measurement of the reactive powerflow computed from the 3-phase phasor measurement of PMU6, located atthe AC port of the inverter 1706. It may be seen that the reactive powerflow is noisier, mostly due to the switching control logic in theinverter 1706. Moreover, the step wise change of the real power hascaused (dynamic) interaction on the reactive power flow at the AC portof the inverter 1706, as the reactive power flow demand signal was setto 0. It may be seen that the inverter again exhibits a slew ratelimitation and a small overshoot in power flow. The red line is adynamic model fitted on the measured data, modeling the inverter slewrate and dynamic response. Main conclusion from this plot is that theSDPM 510 is able to simulate the measured reactive power flow very well.As such, the model may be used for off-line tuning of the UCSD microgridcontroller 1102 to ensure the controller will work with the anticipatedinverter dynamics.

D. Short-Term and Long-Term Performance Validation

1. Real and Reactive Power Tracking

For the actual implementation of the microgrid controller 1704 at theKPRMC site, the control algorithms developed in Matlab/Simulink wereconverted to C++ code and compiled under Microsoft Visual Studio to beable to run in real-time on the Windows Server 2012 SEL3355 computerinstalled at the medical facility. The translation of Matlab/Simulinkcode to C++ code was unit tested by generating random input data for theMatlab/Simulink control algorithm and comparing the output of the C++code given the same input with the output produce by Matlab/Simulink.

Most of the C++ code was associated with the overhead of opening TCP/IPcommunication ports (WinSockets) to allow PMU and modbus data overTCP/IP to flow in/out of the controller 1704. TCP/IP PMU and Modbus dataflow was tested with separate C37.118 and modbus testers. In particular,for the C38.118 communication with the C++ implementation for themicrogrid controller 1704; the PMU connection Tester software by theGrid Protection Alliance was used. For Modbus communication the ModbusSlave by Witte Software (http://www.modbustools.com/) was used.

The closed-loop real and reactive power control tracking of the actualmicrogrid controller 1704 is performed by confirming the power trackingcapabilities of the microgrid controller 1704. To illustrate theperformance of the microgrid controller 1704, measurements of power flowat the PCC/POI were taken at 60 Hz WITH and WITHOUT power tracking andthe results are as illustrated in FIG. 22.

The difference between without/with power tracking is tested andillustrated in FIG. 22 by simply turning on/off the microgrid controller1704. The microgrid controller 1704 has the ability to seamlessly turnon/off and provide for a “bumpless” transfer of power flow when thecontroller is switched on/off. The results in FIG. 22 speak forthemselves and power flow is separated into two figures.

The top figure is the 60 Hz measurement of real power flow obtained bythe PMU 1702 located at the PCC/POI. It may be seen that powerfluctuates+/−100 kW around 425 kW when the microgrid controller 1704 isturned off. As soon the microgrid controller 1704 is tuned on andswitched to power tracking/stabilization mode, the average power flowfluctuations are diminished as the average power flow stays constantaround 425 kW. High frequency fluctuations in power flow may still beobserved due to the 60 Hz sampling rate, but such power flowfluctuations are not controllable due to the much slower update rate ofthe inverter power flow demand signal at 1 Hz. The conclusion of thistest/figure is that power flow may be regulated to a desired value (inthis case of 425 kW and 500 kW) if needed. Such step wise changes indesired power flow at the PCC/POI are in-line with ADR 2.0 demandresponse request and the microgrid controller 1704 is able to providesuch power tracking.

The bottom figure show the demand signal sent to the inverter 1706during the actual closed-loop testing of the microgrid controller 1704.Clearly, zero power demand signals are sent when the microgridcontroller 1704 is turned off, while modulated power to keep the powerflow at the PCC constant despite (internal) power demand fluctuationsoccur within the medical facility.

2. State of Charge (SoC) Gated Real Power

In line with the requirement to manage the SoC of the BESS, SoC-gatedclosed-loop (feedback) control testing of the microgrid controller 1704is used to demonstrate that the microgrid controller 1704 is able tocarefully keep the SoC of the battery 1708 at any desired level.Variations in the SoC of the battery 1708 occur due to the presence ofsolar power and its variations during a full day of operation of thethree-port PPS inverter 1706. The results of SoC tracking for a full dayof operation are illustrated in FIG. 23.

FIG. 23 demonstrates how well the microgrid controller 1704 is able tokeep the SoC of the battery 1708 at a desired level over a whole dayduring PV power generation. FIG. 23 consists of two plots. The topfigure has two lines. The blue line shows the measurement of the PVpower as processed by the PPS BIGI inverter 1706 during the solargeneration part of the day. It may be observed that the solar powerpeaks to approximately 160 kW. The red line shows the active/real powerdemand computed by the microgrid controller 1706 and sent to the PPSBIGI inverter 1706.

From this plot it may be concluded that the real power demand signalnicely follows the generated PV power most of the time, but two largedeviations from the generated PV power may be observed. These two largedeviations coincide with a change in the desired SoC level of thebattery 1708 depicted in the bottom plot. The bottom plot has also twolines. The red lines now refer to the desired SoC level of the battery1708. It may be observed that is set to 50% but a step wise change ismade right after the peak solar generation to go to 55%. The blue lineis the actual measure SoC as reported by the Battery Management System(BMS). From this plot it may be concluded that the measured SoC reportedby the BMS nicely tracks the desired SoC of 50% throughout the timeswhen PV power is changing (ramps up/down), and when the SoC reference ischanged stepwise to 55%, the microgrid controller 1704 modulates theinverter demand signal (AC power output) to ensure the battery 1708reaches the desired SoC of 55% as fast as possible.

It is worth noting that the SoC tracking has been tested for morecomplex SoC tracking profiles, optimized to give the best financialbenefit of charging/discharging the battery 1708 throughout the day. Amore complicated SoC profile and the performance of the microgridcontroller 1704 to be able to track that profile is illustrated in FIG.24. FIG. 24 illustrates closed-loop control testing of the SoC-gatedmicrogrid control for SoC management of the battery 1708 using a SoCreference for a financially optimal battery charging/dischargingprofile.

3. Autonomous SoC-Gated and Demand Limit Real Power Control

In line with the requirement to manage both the SoC of the battery 1708and limited the real power demand at the PCC/POI, the autonomousSoC-gated and Demand Limit closed-loop (feedback) control testing of themicrogrid controller 1704 is used. This fully functional microgridcontrol algorithm now ensures daily battery charging/discharging tominimize ToU pricing, while at the same time limit peak demand at thePOI/PCC to reduce demand charge costs.

An overview of the combined effect of SoC management and demand limitreduction is shown in FIG. 25 that provides a quick overview of all theimportant performance characteristics for a single day, in this case forMay 30, 2018. FIG. 25 provides an overview of daily real power PVproduction and inverter output (top figure), uncontrolled and controlledpower demand at the PCC/POI (middle figure) and SoC with its reference(bottom figure). FIG. 25 illustrates that inverter real real-poweroutput is smoothened (red line, top figure), despite large variations inPV real power production (green line, top figure). At the same time, theinverter 1706 produces power to reduce peak demand (middle figure) andmanage the SoC (bottom figure) to charge/discharge the battery 1708 on adaily schedule.

Long term evaluation of the performance of the microgrid controller 1704is provided by generation of the data displayed in FIG. 25 for everysingle day that the microgrid controller is running. Such images areavailable via a web interface and a sample of multi-daily performance isillustrated in FIG. 26. FIG. 26 is an overview of multi-daily real powerPV production and inverter output (top figure), uncontrolled andcontrolled power demand at the PCC/POI (middle figure) and SoC with itsreference (bottom figure).

Unless otherwise stated, all measurements, values, ratings, positions,magnitudes, sizes, locations, and other specifications that are setforth in this specification, including in the claims that follow, areapproximate, not exact. They are intended to have a reasonable rangethat is consistent with the functions to which they relate and with whatis customary in the art to which they pertain.

The foregoing description of the preferred embodiment has been presentedfor the purposes of illustration and description. While multipleembodiments are disclosed, still other embodiments will become apparentto those skilled in the art from the above detailed description. Thedisclosed embodiments are capable of modifications in various obviousaspects, all without departing from the spirit and scope of theprotection. Accordingly, the detailed description is to be regarded asillustrative in nature and not restrictive. Also, although notexplicitly recited, one or more embodiments may be practiced incombination or conjunction with one another. Furthermore, the referenceor non-reference to a particular embodiment shall not be interpreted tolimit the scope. It is intended that the scope or protection not belimited by this detailed description, but by the claims and theequivalents to the claims that are appended hereto.

Except as stated immediately above, nothing that has been stated orillustrated is intended or should be interpreted to cause a dedicationof any component, step, feature, object, benefit, advantage, orequivalent, to the public, regardless of whether it is or is not recitedin the claims.

What is claimed is:
 1. A microgrid system comprising: a battery energystorage system (BESS”) configured to store direct current (DC)electrical energy therein; one or more renewable energy sourcesconfigured to generate electrical power; a plurality of power consumingloads; a load manager coupled between the BESS and the one or morerenewable energy sources and the plurality of power consuming loads,wherein the load manager includes an inverter configured to providepower to and receive power from the BESS and convert the DC electricalenergy of the BESS; and a microgrid controller coupled to the loadmanager, wherein the microgrid controller is operable to adjust anoutput frequency of the inverter with a control algorithm function inresponse to a state of a frequency of the microgrid, a power transferstate of the load manager, and an energy profile for the BESS, whereinthe algorithm uses a model-based state reconstruction to compensate forsensor and/or communication errors during real-time operation.
 2. Themicrogrid system of claim 1, wherein the control algorithm function usesreal-time feedback measurement of the absolute or relative measure ofthe stored energy level of the BESS, continuous generation of powerdemand or current demand signals for the BESS, and corrects, via themodel-based state reconstruction, measurements representing the absoluteor relative measure for the stored energy level of the BESS.
 3. Amicrogrid system comprising: a battery energy storage system (BESS”)configured to store direct current (DC) electrical energy therein; oneor more renewable energy sources configured to generate electricalpower; a plurality of power consuming loads; a load manager coupledbetween the BESS and the one or more renewable energy sources and theplurality of power consuming loads, wherein the load manager includes aninverter configured to provide power to and receive power from the BESSand convert the DC electrical energy of the BESS; and a microgridcontroller coupled to the load manager, wherein the microgrid controlleris operable to adjust an output frequency of the inverter in response toboth a state of a frequency of the microgrid and a power transfer stateof the load manager, wherein the microgrid controller is operable toimplement, in conjunction with the control algorithm function, a Kalmanfilter operation to generate a model-based state reconstruction of astored energy profile for the BESS.
 4. A microgrid system comprising: abattery energy storage system (BESS”) configured to store direct current(DC) electrical energy therein; one or more renewable energy sourcesconfigured to generate electrical power; a plurality of power consumingloads; a load manager coupled between the BESS and the one or morerenewable energy sources and the plurality of power consuming loadswherein the load manager includes an inverter configured to providepower to and receive power from the BESS and convert the DC electricalenergy of the BESS; and a microgrid controller coupled to the loadmanager wherein the microgrid controller is operable to adjust an outputfrequency of the inverter in response to both a state of a frequency ofthe microgrid and a power transfer state of the load manager, whereinthe microgrid controller is operable to generate, using a controlalgorithm function, a stored energy profile for the BESS, and whereinthe received energy level measurement data is an absolute measure ofenergy stored in the BESS.
 5. A microgrid system comprising: a batteryenergy storage system (BESS”) configured to store direct current (DC)electrical energy therein; one or more renewable energy sourcesconfigured to generate electrical power; a plurality of power consumingloads; a load manager coupled between the BESS and the one or morerenewable energy sources and the plurality of power consuming loads,wherein the load manager includes an inverter configured to providepower to and receive power from the BESS and convert the DC electricalenergy of the BESS; and a microgrid controller coupled to the loadmanager, wherein the microgrid controller is operable to adjust anoutput frequency of the inverter in response to both a state of afrequency of the microgrid and a power transfer state of the loadmanager, wherein the microgrid controller is operable to generate, usinga control algorithm function, a stored energy profile for the BESS, andwherein the received energy level measurement data is a relative measureof energy stored in the BESS.
 6. A microgrid system comprising: abattery energy storage system (BESS”) configured to store direct current(DC) electrical energy therein; one or more renewable energy sourcesconfigured to generate electrical power; a plurality of power consumingloads; a load manager coupled between the BESS and the one or morerenewable energy sources and the plurality of power consuming loads,wherein the load manager includes an inverter configured to providepower to and receive power from the BESS and convert the DC electricalenergy of the BESS; and a microgrid controller coupled to the loadmanager, wherein the microgrid controller is operable to adjust anoutput frequency of the inverter in response to both a state of afrequency of the microgrid and a power transfer state of the loadmanager, wherein the microgrid controller is operable to generate, usinga control algorithm function, a stored energy profile for the BESS, andwherein the microgrid controller is further operable to generate afeedback data stream comprising measurement data associated withoperation of at least one of the BESS, the one more renewable energysources, the inverter, and combinations thereof.
 7. The microgrid systemof claim 6, wherein the microgrid controller is further operable togenerate a reference data stream comprising reference data associatedwith desired stored energy levels for the BESS.
 8. The microgrid systemof claim 7, wherein the microgrid controller is further operable togenerate a control data stream comprising control data for selectivelycontrolling the amount of electrical energy stored in the BESS, whereinthe amount of electrical energy stored in the BESS is determinedaccordance therewith.
 9. The microgrid system of claim 8, wherein themicrogrid controller generates the control data stream by subjecting aleast a portion of the feedback data stream and the reference stream toa feedback control algorithm function.
 10. The microgrid system of claim9, wherein the control data stream includes at least one of currentdispatch commands transmitted to the BESS, AC real power dispatchcommands transmitted to the inverter, and combinations thereof.
 11. Amicrogrid system comprising: a battery energy storage system (BESS”)configured to store direct current (DC) electrical energy therein; oneor more renewable energy sources configured to generate electricalpower; a plurality of power consuming loads; a load manager coupledbetween the BESS and the one or more renewable energy sources and theplurality of power consuming loads, wherein the load manager includes aninverter configured to provide power to and receive power from the BESSand convert the DC electrical energy of the BESS; and a microgridcontroller coupled to the load manager, wherein the microgrid controlleris operable to: adjust an output frequency of the inverter in responseto both a state of a frequency of the microgrid and a power transferstate of the load manager; receive power measurement data associatedwith a power production of the one or more renewable energy sources;receive energy level measurement data associated with an energy level ofthe BESS; selectively control an amount of electrical energy stored inthe BESS based on at least a portion of the power measurement data andthe energy level measurement data; and generate a feedback data streamcomprising measurement data associated with operation of at least one ofthe BESS, the one more renewable energy sources, the inverter, andcombinations thereof, and wherein the microgrid controller is operableto adjust an output frequency of the inverter with a control algorithmfunction in response to a state of a frequency of the microgrid, a powertransfer state of the load manager, and an energy profile for the BESS,wherein the algorithm uses a model-based state reconstruction tocompensate for sensor and/or communication errors during real-timeoperation.
 12. The microgrid system of claim 11, wherein the microgridcontroller is operable to generate, using a control algorithm function,a stored energy profile for the BESS.
 13. The microgrid system of claim12, wherein the microgrid controller is operable to implement, inconjunction with the control algorithm function, a Kalman filteroperation to generate a model based state reconstruction of a storedenergy profile for the BESS.
 14. The microgrid system of claim 12,wherein the received energy level measurement data is an absolutemeasure of energy stored in the BESS.
 15. The microgrid system of claim12, wherein the received energy level measurement data is a relativemeasure of energy stored in the BESS.
 16. The microgrid system of claim11, wherein the microgrid controller is further operable to generate afeedback data stream comprising reference data associated with desiredstored energy levels for the BESS.
 17. The microgrid system of claim 16,wherein the microgrid controller is further operable to generate acontrol data stream comprising control data for selectively controllingthe amount of electrical energy stored in the BESS, wherein the amountof electrical energy stored in the BESS is determined accordancetherewith.
 18. The microgrid system of claim 17, wherein the microgridcontroller generates the control data stream by subjecting a least aportion of the feedback data stream and the reference stream to afeedback control algorithm function.
 19. The microgrid system of claim18, wherein the control data stream includes at least one of currentdispatch commands transmitted to the BESS, AC real power dispatchcommands transmitted to the inverter, and combinations thereof.
 20. Themicrogrid system of claim 1, wherein the model-based statereconstruction models an effect of random fluctuations in the dynamicprogression of the stored energy in the BESS.
 21. The microgrid systemof claim 1, wherein the microgrid controller adjusts the outputfrequency of the inverter to achieve a desired state of charge profilefor the BESS.
 22. The microgrid system of claim 1, wherein the microgridcontroller continuously processes a reference data stream and a feedbackdata stream to compute a desired active power dispatch for the inverterto either charge, discharge, or level the energy or charge level of theBESS.
 23. The microgrid system of claim 1, wherein the control algorithmfunction includes an error detection threshold set to detect ameasurement error based upon deviation from a reconstruction model ofstored energy in the BESS.
 24. The microgrid system of claim 1, whereinthe microgrid controller comprises a Phasor Measurement Unit to providereal-time updates on the electrical properties and real/reactive powerflow of the microgrid and compensates for unanticipated real/reactivepower fluctuations in real time by switching the BESS between storageand delivery.
 25. The microgrid system of claim 1, wherein the microgridcontroller comprises a Phasor Measurement Unit to provide real-timeupdates on the electrical properties and real/reactive power flow of themicrogrid and a decoupling filter achieve the decoupling of real andreactive power flow at a coupling of the microgrid to a main grid.